{extend name="$admin_layout" /}
{block name="content"}
<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <!-- 引入样式 -->
    <link rel="stylesheet" href="/static/statistics/css/base.css">
    <link rel="stylesheet" href="/static/statistics/css/orderDetail.css">
    <!-- element -->
    <link rel="stylesheet" href="/static/plugins/element-ui/element-ui.css">
    <!-- vue -->
    <script src="/static/plugins/vue/vue.min.js"></script>
    <!-- 引入组件库 element -->
    <script src="/static/plugins/element-ui/element-ui.js"></script>
    <style>
        .btn-list{
            margin-bottom: 20px;
        }
        .el-button{
            padding: 5px 10px;
        }
        .box-drawer{
            padding: 25px;
        }
        .box-drawer-btn{
            display: flex;
            justify-content: center;
            height: 80px;
            align-items: center;
        }
    </style>
</head>

<body>
    <div id="el">
        <div class="fu-order-detail-tips">{:lang('打印发货单')}</div>

 
        <input type="hidden" id="sender_list" name="sender_list" value="{$sender_list}">
        <input type="hidden" id="express_company" name="express_company" value="{$express_company}">
        <input type="hidden" id="sender_company" name="sender_company" value="{$sender_company}">
        <!--<div class="invoice-textarea-wrap">-->
            <!--<div class="invoice-textarea">-->
                <!---->
            <!--</div>-->
        <!--</div>-->
        <el-card class="box-card">
            <div slot="header" class="clearfix">
                <span>{:lang('操作信息')}</span>
            </div>
            <form action="{$Request.url}" method="post">

            <div style="margin-bottom: 10px;display: flex;justify-content: flex-start;padding-left: 200px;width: 800px;align-items: center;">
                <div style="width: 150px;text-align: right;">{:lang('选择快递公司')}：</div>
                <div style="width: 600px;">
                    <el-select v-model="expressValue" placeholder="{:lang('请选择')}">
                        <el-option
                                v-for="item in express_company"
                                :key="item.aid"
                                :label="item.name"
                                :value="item.aid">
                        </el-option>
                    </el-select>
                </div>
            </div>
                <div style="margin-bottom: 10px;display: flex;justify-content: flex-start;padding-left: 200px;width: 800px">
                    <div style="width: 150px;text-align: right;">{:lang('选择发货人')}：</div>
                    <div style="width: 600px;">
                        <el-select v-model="senderValue" placeholder="{:lang('请选择')}">
                            <el-option
                                    v-for="item in sender_company"
                                    :key="item.id"
                                    :label="item.name"
                                    :value="item.id">
                            </el-option>
                        </el-select>
                    </div>
                </div>
            <div style="margin-bottom: 10px;display: flex;justify-content: flex-start;padding-left: 200px;width: 800px">
                <div style="width: 100px;text-align: right;">{:lang('操作备注')}：</div>
                <div style="width: 600px;">
                    <el-input
                            type="textarea"
                            :autosize="{ minRows: 4, maxRows: 8 }"
                            placeholder="{:lang('请输入内容')}"
                            v-model="textarea">
                    </el-input>
                </div>
            </div>
                <input type="hidden" value="{$order_info.order_sn}" name="order_sn">
                <input type="hidden" :value="expressValue" name="express_company">
                <input type="hidden" :value="senderValue" name="sender_company">
                <input type="hidden" :value="textarea" name="remark">
            <div style="margin-bottom: 10px;display: flex;justify-content: space-between;padding-left: 290px;width: 800px;margin-bottom: 20px;">
                <div>
                    <button type="submit" class="el-button el-button--default el-button--primary " value="submit">{:lang('确认生成发货单')}</button>
                    <!--<el-button >取消</el-button>-->
                    <!--<el-button type="primary">主要按钮</el-button>-->
                    <!--<el-button type="primary">主要按钮</el-button>-->
                </div>
                <!--<div>-->
                    <!--<el-button >主要按钮</el-button>-->
                <!--</div>-->
            </div>

           </form>
  
        </el-card>
    </div>
</body>
<script>
    let sender_list = JSON.parse($('#sender_list').val());
    let express_company = JSON.parse($('#express_company').val());
    let sender_company = JSON.parse($('#sender_company').val());
    let senderValue = sender_company.length>0 ?sender_company[0].id:'';
    let expressValue = express_company.length>0 ?express_company[0].aid:'';

    new Vue({
        el: '#el',
        data() {
            return {           
                drawer:false,
                direction: 'rtl',
                textarea2:'',
                textarea:'',
                type:1,
                tableList:[],
                sender_list:sender_list || [],
                express_company:express_company || [],
                sender_company:sender_company || [],
                senderValue:senderValue,
                expressValue:expressValue,
                value: ''
            }
        },
        mounted() {

        },
        methods: {
            handleClose(done) {
                this.$confirm("{:lang('确认关闭')}"+'？')
                    .then(_ => {
                        done();
                    })
                    .catch(_ => {});
            },
            cancel(){
                this.drawer = false;
            },
            openDrawer(type){
                this.drawer = true;
                this.type = type;
            }
        },
    })
</script>

</html>
{/block}